#ifndef MYTCPSERVER_H
#define MYTCPSERVER_H
#include <QTcpServer>
#include "mytcpsocket.h"

class MyTcpServer : public QTcpServer
{
    Q_OBJECT
public:
    MyTcpServer();
    static MyTcpServer& getInstance();
    void incomingConnection(qintptr handle);
    void deleteSocket(MyTcpSocket* mysocket);
    void resend(char* tarName, PDU* pdu);

private:
    QList<MyTcpSocket*> m_tcpSocketList;

    MyTcpServer(const MyTcpServer& instance) = delete;
    MyTcpServer& operator = (const MyTcpServer&) = delete;

};

#endif // MYTCPSERVER_H
